home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group93b.txt / 000078_icon-group-sender _Mon May 10 16:03:02 1993.msg < prev    next >
Internet Message Format  |  1993-06-16  |  2KB

  1. Received: by cheltenham.cs.arizona.edu; Tue, 11 May 1993 10:22:43 MST
  2. Date: 10 May 93 16:03:02 GMT
  3. From: dog.ee.lbl.gov!network.ucsd.edu!news.cerf.net!netlabs!lwall@ucbvax.Berkeley.EDU  (Larry Wall)
  4. Organization: NetLabs, Inc.
  5. Subject: Re: runtime debugger and the Icon fan club.
  6. Message-Id: <1993May10.160302.6574@netlabs.com>
  7. References: <1993Apr29.141749.24949@midway.uchicago.edu>, <1993May7.182643.26824@netlabs.com>, <1993May7.205551.1831@midway.uchicago.edu>
  8. Sender: icon-group-request@cs.arizona.edu
  9. To: icon-group@cs.arizona.edu
  10. Status: R
  11. Errors-To: icon-group-errors@cs.arizona.edu
  12.  
  13. In article <1993May7.205551.1831@midway.uchicago.edu> goer@midway.uchicago.edu writes:
  14. : lwall@netlabs.com (Larry Wall) writes:
  15. : >
  16. : >: [Icon programmers] mainly use the semicolon to separate two expres-
  17. : >: sions abutted on the same line.  Generally it is lacking from idiomatic
  18. : >: Icon code, and with good reason:  It is generally superfluous even in
  19. : >: languages that force one to use it!
  20. : >
  21. : >Not to contradict a valid assertion, but as a point of interest it's
  22. : >not superfluous in Perl, since it switches the lexer from expecting an
  23. : >operator to expecting a term, just as any other operator would.
  24. : So, for example, if we see INTEGER 1, then OP '*', then INTEGER 1, if
  25. : we then see a ';' the lexer knows that the next thing is not going to be an
  26. : operator?  Maybe I'm not understanding, but wouldn't a newline accom-
  27. : plish the same thing?
  28. :     1 * 1;
  29. :     2 * 2...
  30. : vs.
  31. :     1 * 1
  32. :     2 * 2...
  33.  
  34. Certainly, if you're willing to place that kind of syntactic load on a
  35. newline.  I don't happen to be, probably for irrational reasons--I once
  36. got a bad taste in my mouth from the way awk does it.  I much prefer
  37. that a newline character be treated (by default) as nothing more than a
  38. funny-looking space character, in the tradition of so-called "free-form"
  39. languages.  Only in the explicitly line-oriented constructs of Perl
  40. (here-docs and formats) are newlines syntactically different from spaces.
  41.  
  42. Hmm, looking back at that last paragraph I wrote, I only see one period
  43. at the end of a line, and that one, being at the end of a paragraph, is
  44. superfluous...  :-)
  45.  
  46. Larry
  47.